using System.ComponentModel.DataAnnotations;
using SqlSugar;

namespace FytSoa.Domain.Erp;

/// <summary>
/// erp-盘点明细表
/// </summary>
[SugarTable("erp_takestock_detail")]
public class ErpTakestockDetail:Entity
{
    /// <summary>
    /// 盘点单编号
    /// </summary>
    [Required]
    public long OrderId { get; set; }

    /// <summary>
    /// 产品编号
    /// </summary>
    [Required]
    public long ProductId { get; set; }

    /// <summary>
    /// 原库存数量
    /// </summary>
    [Required]
    public int SourceCount { get; set; } = 0;

    /// <summary>
    /// 新库存数量
    /// </summary>
    [Required]
    public int NewCount { get; set; } = 0;

    /// <summary>
    /// 盈亏金额
    /// </summary>
    [Required]
    public decimal PAL { get; set; }

    /// <summary>
    /// 盘存类型枚举
    /// </summary>
    [Required]
    public int CheckType { get; set; } = 1;

    /// <summary>
    /// 创建人
    /// </summary>
    public string CreateUser { get; set; }

    /// <summary>
    /// 创建时间
    /// </summary>
    [Required]
    public DateTime CreateTime { get; set; } = DateTime.Now;

    /// <summary>
    /// 更新人
    /// </summary>
    public string UpdateUser { get; set; }

    /// <summary>
    /// 更新时间
    /// </summary>
    public DateTime? UpdateTime { get; set; }


}